

<div class="container">
    <?php include 'member-left.php'; ?>

    <div class="col_r w765">
        <div class="linkmain">
            <ul class="tab_product">
                <li ><a href="/thanh-vien?mid=<?php echo $_SESSION['client']['id']; ?>&action=hopthu">Hộp thư đến</a></li>
                <li class="active"><a href="/thanh-vien?mid=<?php echo $_SESSION['client']['id']; ?>&action=thudagui">Hộp thư đi</a></li>
            </ul>
            <div class="right"><input type="button" class="btnBlogComment left" value="Viết tin nhắn" name="btnCompose" id="btnCompose" onclick="javascript:showSendMsg();"></div>
        </div>
        <?php
        $arrInbox = $member->mailSent();
        ?>
        <div class="title_mb_bg3">
            <ul>
                <li class="top">
                    <div class="col1"><input type="checkbox" class="chkCheckAll" /></div>
                    <div class="col2"><a href="javascript:;" id="deleteMail" lang="sent">Xóa các thư đã chọn</a></div>
                    <div class="col3">Người nhận</div>
                    <div class="col4">Thời gian</div>
                </li>
                <?php
                $i = 0;
                foreach ($arrInbox as $key => $row) {
                    $i++;
                    ?>
                    <li<?php echo $i == count($arrInbox) ? ' class="end"' : '' ?> id="mail_<?php echo $row['id'];?>">
                        <div class="col1"><input type="checkbox" class="chkCheckElement" value="<?php echo $row['id']; ?>" /></div>
                        <div class="col2 unread"><a class="clickShowMail" href="javascript:;" title="Đọc thư"><?php echo $row['title']; ?></a></div>
                        <div class="col3"><a href="javascript:;" onclick="showSendMsgTo('<?php echo $row['sender']['id']; ?>')"><?php echo $row['sender']['fullname']; ?></a></div>
                        <div class="col4"><?php echo date('d/m H:i', strtotime($row['create_date'])); ?></div>
                        <div class="mailContent"><?php echo $row['content']; ?></div>
                    </li>
                    <?php
                }
                ?>


            </ul>
        </div>

        <!--div class="dangtin_un">
            <span class="dt_un_r">
                <a href="#">Trang trước</a> | <a href="#">Trang sau</a>
            </span>
        </div-->

    </div>

</div>

<script src="/js/inbox.js" type="text/javascript"></script>